/* 基础样式 */
:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --text-color: #333;
    --text-light: #7f8c8d;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f5f7fa;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--accent-color);
}

ul {
    list-style: none;
}

/* 布局样式 */
.resume-container {
    display: flex;
    max-width: 1200px;
    margin: 2rem auto;
    background: white;
    box-shadow: var(--box-shadow);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.sidebar {
    flex: 0 0 300px;
    background: var(--secondary-color);
    color: white;
    padding: 2rem;
}

.main-content {
    flex: 1;
    padding: 2rem;
}

/* 个人信息卡片 */
.profile-card {
    text-align: center;
}

.profile-img-container {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid rgba(255, 255, 255, 0.2);
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.online-status {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 15px;
    height: 15px;
    background-color: #2ecc71;
    border-radius: 50%;
    border: 2px solid var(--secondary-color);
}

.job-title {
    color: var(--light-color);
    margin-bottom: 1.5rem;
    font-weight: 300;
    font-size: 1.1rem;
}

/* 联系信息 */
.contact-info {
    margin: 2rem 0;
}

.contact-info h3 {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.contact-info h3 i {
    margin-right: 0.5rem;
}

.contact-info ul li {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

.contact-info ul li i {
    margin-right: 0.8rem;
    width: 20px;
    text-align: center;
    color: var(--primary-color);
}

/* 技能条 */
.skills {
    margin: 2rem 0;
}

.skills h3 {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.skills h3 i {
    margin-right: 0.5rem;
}

.skill-item {
    margin-bottom: 1.2rem;
}

.skill-item p {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.skill-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.skill-level {
    height: 100%;
    background: var(--primary-color);
    border-radius: 4px;
}

/* 兴趣爱好 */
.hobbies {
    margin: 2rem 0;
}

.hobbies h3 {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.hobbies h3 i {
    margin-right: 0.5rem;
}

.hobby-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hobby-tags span {
    padding: 0.3rem 0.8rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 0.85rem;
}

/* 主要内容区 */
.section {
    margin-bottom: 2.5rem;
}

.section h2 {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
    font-size: 1.5rem;
    border-bottom: 2px solid var(--light-color);
    padding-bottom: 0.5rem;
}

.section h2 i {
    margin-right: 0.8rem;
    color: var(--primary-color);
}

/* 时间线样式 */
.timeline {
    padding-left: 30px; /* 增加左侧留白 */
}

.timeline-date {
    left: -85px; /* 调整位置 */
    width: 100px;
    text-align: right;
    padding-right: 15px;
    box-sizing: border-box;
    background: var(--primary-color);
    color: white;
    border-radius: 4px;
}
  
.timeline-content {
    margin-left: 0; /* 重置原有margin */
}

.timeline::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 0;
    height: 100%;
    width: 2px;
    background: var(--primary-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-content h3 {
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

.subtitle {
    color: var(--text-light);
    margin-bottom: 0.8rem;
    font-size: 0.95rem;
}

/* 项目卡片 */
.projects {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.project-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 1.5rem;
    transition: var(--transition);
    border-left: 4px solid var(--primary-color);
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.project-header h3 {
    color: var(--secondary-color);
}

.project-date {
    background: var(--light-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-light);
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-tech span {
    padding: 0.3rem 0.8rem;
    background: var(--light-color);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--secondary-color);
}

.project-details p {
    margin-bottom: 0.8rem;
}

.project-details ul {
    margin: 1rem 0 1rem 1.5rem;
}

.project-details ul li {
    list-style-type: disc;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.project-link {
    display: inline-flex;
    align-items: center;
    margin-top: 1rem;
    padding: 0.5rem 1rem;
    background: var(--primary-color);
    color: white;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    transition: var(--transition);
}

.project-link:hover {
    background: var(--accent-color);
    color: white;
}

.project-link i {
    margin-right: 0.5rem;
}

/* 获奖情况 */
.awards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.award-item {
    display: flex;
    gap: 1.5rem;
}

.award-icon {
    flex: 0 0 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-color);
    border-radius: 50%;
}

.award-icon i {
    font-size: 1.5rem;
}

.award-icon .gold {
    color: gold;
}

.award-icon .silver {
    color: silver;
}

.award-content h3 {
    color: var(--secondary-color);
    margin-bottom: 0.3rem;
}

.award-date {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* 页脚 */
.footer {
    text-align: center;
    padding: 1.5rem;
    background: var(--secondary-color);
    color: white;
    font-size: 0.9rem;
}

.social-links {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.social-links a {
    color: white;
    font-size: 1.2rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--primary-color);
}

.print-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem !important;
}

/* 响应式设计 */
@media screen and (max-width: 992px) {
    .resume-container {
        flex-direction: column;
        margin: 0;
        border-radius: 0;
    }
    
    .sidebar {
        flex: 1;
        width: 100%;
    }
    
    .main-content {
        padding: 1.5rem;
    }
    
    .profile-img-container {
        width: 120px;
        height: 120px;
    }
}

@media screen and (max-width: 768px) {
    .award-item {
        flex-direction: column;
        gap: 1rem;
    }
    
    .award-icon {
        align-self: flex-start;
    }
    
    .project-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .project-date {
        align-self: flex-start;
    }
}

@media print {
    body {
        background: none;
        font-size: 12pt;
    }
    
    .resume-container {
        box-shadow: none;
    }
    
    .sidebar {
        background: var(--secondary-color) !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .footer {
        display: none;
    }
    
    a::after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
        font-weight: normal;
        color: var(--text-light);
    }
}